package com.services;

import java.util.List;

import com.DAO.DepartmentRepository;
import com.DAO.impl.DepartmentRepositoryImpl;
import com.beans.Department;

public class DepartmentService {
	private DepartmentRepository dep = new DepartmentRepositoryImpl();
	
	public List<Department> selectAll(){
		return dep.selectAll();
	}
	public void delete(int departmentSno) {
		dep.delete(departmentSno);
	}
	public Department findById(int departmentSno) {
		return dep.findById(departmentSno);
	}
	public void add(int departmentSno, String departmentName, int amount,String phoneNum) {
		dep.add(departmentSno, departmentName, amount, phoneNum);
	}
	public void update(int departmentSno, String departmentName, int amount,String phoneNum) {
		dep.update(departmentSno, departmentName, amount, phoneNum);
	}
}
